(function () {
    'use strict';

    angular
        .module('app.ForgotPassword')
        .controller('SearchScreenController', SearchScreenController);

    SearchScreenController.$inject = ['logger','$state','$rootScope','UserContextData','$mdDialog','$timeout'];
    /* @ngInject */
    function SearchScreenController(logger, $state, $rootScope, UserContextData,$mdDialog,$timeout) {
        var vm = this;
        vm.title = 'SearchScreen';
        vm.user = "";
        vm.password = "";
        vm.ErrorMessage = "";
        vm.CancelClick = CancelClick;
        vm.SearchClick = SearchClick;
        activate();
        
        function activate() {
        }

        function CancelClick() {
            $mdDialog.hide();
        };
        
        function SearchClick() {
            $rootScope.CurrentSearch = vm.SearchText;
            $state.go('category', { Type: 'Search', Category: vm.SearchText });
        }

        
    }
})();


